package cn.edu.lingnan.test;

public class Proxy implements Rent{
    private Rent rent;
    public void setRent(Rent rent) {
        this.rent = rent;
    }
    @Override
    public void rent() {
        seeHouse();
        rent.rent();//这里调用的是Landlord里面的rent
    }
    public void seeHouse(){
        System.out.println("带客户看房子");
    }
}
